<!DOCTYPE HTML>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>AUI快速完成布局</title>
    <link rel="stylesheet" type="text/css" href="../css/aui.css" />
    <link rel="stylesheet" type="text/css" href="../css/style.css" />
    <style type="text/css">
        .aui-content-padded {
            padding: 0.75rem;
            background-color: #ffffff;
            margin-top: 0.75rem;
        }

        body {
            background-color: #fff;
            overflow: scroll;
        }
    </style>
</head>

<body>
    <h1>地图页面</h1>
    <div class="footer-extend"></div>
</body>
<script type="text/javascript" src="../script/api.js"></script>
<script type="text/javascript" src="../script/jquery-3.2.1.min.js"></script>
<script type="text/javascript">
    apiready = function() {
        api.parseTapmode();
        $(window).scroll(function(event) {
            if ($(".course-table-header").position().top > 44) {
                $(".course-table-header").addClass("shadow");
            } else {
                $(".course-table-header").removeClass("shadow");
            }
        });
        var map = api.require('bMap');
        map.initMapSDK(function(ret) {
            if (ret.status) {
                alert('地图初始化成功，可以从百度地图服务器检索信息了！');
            }
        });
        map.open({
            rect: {
                x: 0,
                y: 0,
                w: 320,
                h: 300
            },
            center: {
                lon: 116.4021310000,
                lat: 39.9994480000
            },
            zoomLevel: 10,
            showUserLocation: true,
            fixedOn: api.frameName,
            fixed: true
        }, function(ret) {
            if (ret.status) {
                alert('地图打开成功');
            }
        });
    }

    function searchBarOnclick() {
        api.openWin({
            name: 'course_search_win',
            url: './course/search_win.html',
            animation: {
                type: "none",
                subType: "from_bottom",
                duration: 300
            },
            bgColor: '#F2F4F5'
        });

    }

    function classItemOnclick(el) {
        api.openWin({
            name: 'course_my_detail_win',
            url: './course/my_detail_win.html',
            vScrollBarEnabled: false
        });

    }
</script>

</html>
